package com.hhkj.admin.sale.service.base;

import com.hhkj.admin.sale.common.cont.SaleCommissionConst;
import com.hhkj.admin.sale.domain.SaleCommission;
import com.hhkj.admin.sale.model.dopo.SaleCommissionCountPo;
import com.hhkj.admin.sale.model.dopo.SaleCommissionDo;
import com.hhkj.admin.sale.model.dopo.SaleCommissionPo;
import com.ruoyi.common.base.biz.service.base.BaseService;

import java.util.List;

/**
 * @author admin
 * @description 针对表【s_sale_commission(记录每笔分佣情况)】的数据库操作Service
 * @createDate 2023-10-27 14:59:05
 */
public interface SaleCommissionService
        extends BaseService<SaleCommission, SaleCommissionDo, SaleCommissionPo> {

    /**
     * 获取销售分佣金额统计
     *
     * @param saleId 销售id
     * @return 统计信息
     */
    SaleCommissionCountPo countPriceBySaleId(Long saleId);

    /**
     * 批量修改状态
     *
     * @param idList     佣金id列表
     * @param statusCode
     * @return
     */
    boolean updateStatusBatchByIdList(List<Long> idList, SaleCommissionConst.StatusCode statusCode);

}
